/*******************************************************************************
 * Size: 20 px
 * Bpp: 4
 * Opts: --bpp 4 --size 20 --no-compress --font 微软雅黑Bbold.ttf --symbols  眠动学作食· --format lvgl -o lv_font_yahei_bold_20.c
 ******************************************************************************/
#define LV_LVGL_H_INCLUDE_SIMPLE
#ifdef LV_LVGL_H_INCLUDE_SIMPLE
#include "lvgl.h"
#else
#include "lvgl/lvgl.h"
#endif

#ifndef LV_FONT_YAHEI_BOLD_20
#define LV_FONT_YAHEI_BOLD_20 1
#endif

#if LV_FONT_YAHEI_BOLD_20

/*-----------------
 *    BITMAPS
 *----------------*/

/*Store the image of the glyphs*/
static LV_ATTRIBUTE_LARGE_CONST const uint8_t glyph_bitmap[] = {
    /* U+0020 " " */

    /* U+00B7 "·" */
    0x0, 0x42, 0x0, 0xbf, 0xf6, 0xf, 0xff, 0xa0,
    0x6f, 0xd3,

    /* U+4F5C "作" */
    0x0, 0x0, 0x42, 0x0, 0x5, 0x62, 0x0, 0x0,
    0x0, 0x0, 0x0, 0x0, 0xf, 0xfc, 0x0, 0xdf,
    0xe0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x4, 0xff,
    0x80, 0x2f, 0xfa, 0x0, 0x0, 0x0, 0x0, 0x0,
    0x0, 0xaf, 0xf2, 0x9, 0xff, 0xb9, 0x99, 0x99,
    0x99, 0x90, 0x0, 0x1f, 0xfc, 0x0, 0xef, 0xff,
    0xff, 0xff, 0xff, 0xff, 0x10, 0x8, 0xff, 0x80,
    0x7f, 0xff, 0xff, 0xff, 0xff, 0xff, 0xf1, 0x1,
    0xff, 0xf8, 0x1e, 0xff, 0x2f, 0xfa, 0x0, 0x0,
    0x0, 0x0, 0x8f, 0xff, 0x89, 0xff, 0x81, 0xff,
    0xa0, 0x0, 0x0, 0x0, 0x2f, 0xff, 0xf8, 0xdf,
    0xe1, 0x1f, 0xfd, 0x88, 0x88, 0x70, 0x6, 0xff,
    0xff, 0x84, 0xf5, 0x1, 0xff, 0xff, 0xff, 0xff,
    0x0, 0x2f, 0xdf, 0xf8, 0x6, 0x0, 0x1f, 0xff,
    0xff, 0xff, 0xe0, 0x0, 0xe3, 0xff, 0x80, 0x0,
    0x1, 0xff, 0xa0, 0x0, 0x0, 0x0, 0x3, 0x1f,
    0xf8, 0x0, 0x0, 0x1f, 0xfa, 0x0, 0x0, 0x0,
    0x0, 0x1, 0xff, 0x80, 0x0, 0x1, 0xff, 0xff,
    0xff, 0xff, 0x60, 0x0, 0x1f, 0xf8, 0x0, 0x0,
    0x1f, 0xff, 0xff, 0xff, 0xf6, 0x0, 0x1, 0xff,
    0x80, 0x0, 0x1, 0xff, 0xd8, 0x88, 0x88, 0x30,
    0x0, 0x1f, 0xf8, 0x0, 0x0, 0x1f, 0xfa, 0x0,
    0x0, 0x0, 0x0, 0x1, 0xff, 0x80, 0x0, 0x1,
    0xff, 0xa0, 0x0, 0x0, 0x0, 0x0, 0x1f, 0xf8,
    0x0, 0x0, 0x1f, 0xfa, 0x0, 0x0, 0x0, 0x0,
    0x1, 0xff, 0x80, 0x0, 0x1, 0xff, 0xa0, 0x0,
    0x0, 0x0,

    /* U+52A8 "动" */
    0x0, 0x0, 0x0, 0x0, 0x0, 0xf, 0xf9, 0x0,
    0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0xff,
    0x80, 0x0, 0x0, 0xf, 0xff, 0xff, 0xff, 0x80,
    0xf, 0xf8, 0x0, 0x0, 0x0, 0xff, 0xff, 0xff,
    0xf8, 0x23, 0xff, 0x92, 0x22, 0x21, 0x7, 0x77,
    0x77, 0x77, 0x5f, 0xff, 0xff, 0xff, 0xff, 0xa0,
    0x0, 0x0, 0x0, 0x1, 0xff, 0xff, 0xff, 0xff,
    0xf9, 0x67, 0x77, 0x77, 0x77, 0x73, 0x3f, 0xf8,
    0x22, 0xff, 0x9d, 0xff, 0xff, 0xff, 0xff, 0x21,
    0xff, 0x70, 0xf, 0xf9, 0xdf, 0xff, 0xff, 0xff,
    0xf2, 0x2f, 0xf6, 0x0, 0xff, 0x80, 0x8, 0xff,
    0x50, 0x0, 0x3, 0xff, 0x50, 0xf, 0xf8, 0x0,
    0xcf, 0xf2, 0x77, 0x0, 0x4f, 0xf5, 0x0, 0xff,
    0x80, 0x1f, 0xfa, 0x7f, 0xf0, 0x5, 0xff, 0x30,
    0xf, 0xf7, 0x6, 0xff, 0x51, 0xff, 0x60, 0x8f,
    0xf2, 0x1, 0xff, 0x70, 0xbf, 0xf0, 0xc, 0xfc,
    0xb, 0xff, 0x0, 0x1f, 0xf7, 0x1f, 0xfb, 0x0,
    0x7f, 0xf2, 0xff, 0xc0, 0x2, 0xff, 0x6a, 0xff,
    0xfe, 0xff, 0xff, 0xdf, 0xf7, 0x0, 0x2f, 0xf6,
    0xaf, 0xff, 0xff, 0xff, 0xff, 0xff, 0x20, 0x5,
    0xff, 0x52, 0xff, 0xfd, 0xcb, 0x9d, 0xff, 0xa6,
    0xdd, 0xff, 0xf4, 0x3, 0x10, 0x0, 0x3, 0xff,
    0xf3, 0x3f, 0xff, 0xff, 0x10, 0x0, 0x0, 0x0,
    0x6, 0xf8, 0x0, 0xff, 0xec, 0x40, 0x0, 0x0,
    0x0, 0x0, 0x2, 0x0, 0x0, 0x0, 0x0, 0x0,

    /* U+5B66 "学" */
    0x0, 0x0, 0x70, 0x0, 0x17, 0x70, 0x0, 0x3,
    0x0, 0x0, 0x0, 0x2d, 0xfa, 0x0, 0xdf, 0xf2,
    0x0, 0x3f, 0xd5, 0x0, 0x0, 0xb, 0xff, 0x70,
    0x4f, 0xfb, 0x0, 0xdf, 0xfa, 0x0, 0x2, 0x23,
    0xff, 0xc2, 0x2d, 0xfa, 0x29, 0xff, 0xd2, 0x20,
    0xe, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff,
    0xff, 0xf5, 0xe, 0xff, 0xff, 0xff, 0xff, 0xff,
    0xff, 0xff, 0xff, 0xf5, 0xe, 0xfd, 0x44, 0x44,
    0x44, 0x44, 0x44, 0x44, 0x9f, 0xf5, 0xe, 0xfd,
    0x15, 0x55, 0x55, 0x55, 0x55, 0x54, 0x6f, 0xf5,
    0x9, 0xa8, 0x3f, 0xff, 0xff, 0xff, 0xff, 0xfc,
    0x4a, 0xa3, 0x0, 0x0, 0x3f, 0xff, 0xff, 0xff,
    0xff, 0xfc, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0,
    0x0, 0x2b, 0xff, 0xc2, 0x0, 0x0, 0x0, 0x0,
    0x0, 0x0, 0x7, 0xff, 0xe6, 0x0, 0x0, 0x0,
    0x3f, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff,
    0xff, 0xfa, 0x3f, 0xff, 0xff, 0xff, 0xff, 0xff,
    0xff, 0xff, 0xff, 0xfb, 0x17, 0x77, 0x77, 0x77,
    0x7d, 0xff, 0x87, 0x77, 0x77, 0x75, 0x0, 0x0,
    0x0, 0x0, 0xb, 0xff, 0x10, 0x0, 0x0, 0x0,
    0x0, 0x0, 0x0, 0x0, 0xc, 0xff, 0x10, 0x0,
    0x0, 0x0, 0x0, 0x0, 0x6, 0x87, 0xaf, 0xff,
    0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x8, 0xff,
    0xff, 0xfb, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0,
    0x4, 0xff, 0xfe, 0xa1, 0x0, 0x0, 0x0, 0x0,
    0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0,
    0x0, 0x0,

    /* U+7720 "眠" */
    0xff, 0xff, 0xff, 0x28, 0xff, 0xff, 0xff, 0xff,
    0xff, 0xf, 0xff, 0xff, 0xf2, 0x8f, 0xff, 0xff,
    0xff, 0xff, 0xf0, 0xff, 0x41, 0xff, 0x28, 0xff,
    0x44, 0x44, 0x4a, 0xff, 0xf, 0xf4, 0x1f, 0xf2,
    0x8f, 0xe0, 0x0, 0x0, 0x8f, 0xf0, 0xff, 0x63,
    0xff, 0x28, 0xff, 0x55, 0x55, 0x5a, 0xff, 0xf,
    0xff, 0xff, 0xf2, 0x8f, 0xff, 0xff, 0xff, 0xff,
    0xf0, 0xff, 0xcb, 0xff, 0x28, 0xff, 0xff, 0xff,
    0xff, 0xff, 0xf, 0xf4, 0x1f, 0xf2, 0x8f, 0xe0,
    0xf, 0xf6, 0x0, 0x0, 0xff, 0x41, 0xff, 0x28,
    0xfe, 0x0, 0xef, 0x70, 0x0, 0xf, 0xfb, 0x9f,
    0xf2, 0x8f, 0xff, 0xff, 0xff, 0xff, 0xfd, 0xff,
    0xff, 0xff, 0x28, 0xff, 0xff, 0xff, 0xff, 0xff,
    0xdf, 0xf7, 0x5f, 0xf2, 0x8f, 0xf5, 0x5b, 0xfd,
    0x55, 0x54, 0xff, 0x41, 0xff, 0x28, 0xfe, 0x0,
    0x6f, 0xd0, 0x9, 0x3f, 0xf4, 0x1f, 0xf2, 0x8f,
    0xe0, 0x4, 0xff, 0x2, 0xff, 0xff, 0xee, 0xff,
    0x28, 0xfe, 0x6, 0x9f, 0xf4, 0x3f, 0xdf, 0xff,
    0xff, 0xf2, 0xbf, 0xfb, 0xf8, 0xdf, 0xa7, 0xfa,
    0xff, 0x41, 0xff, 0x3f, 0xff, 0xff, 0x57, 0xff,
    0xff, 0x7c, 0xd3, 0x9, 0x91, 0xbf, 0xfa, 0x10,
    0x1e, 0xff, 0xf3, 0x0, 0x0, 0x0, 0x3, 0xd4,
    0x0, 0x0, 0x3d, 0xe7, 0x0, 0x0, 0x0, 0x0,
    0x0, 0x0, 0x0, 0x0, 0x0, 0x0,

    /* U+98DF "食" */
    0x0, 0x0, 0x0, 0x0, 0xaf, 0xf8, 0x0, 0x0,
    0x0, 0x0, 0x0, 0x0, 0x0, 0xa, 0xff, 0xff,
    0x50, 0x0, 0x0, 0x0, 0x0, 0x0, 0x2, 0xcf,
    0xfc, 0xef, 0xf8, 0x0, 0x0, 0x0, 0x0, 0x0,
    0x6e, 0xff, 0xb0, 0x2d, 0xff, 0xd3, 0x0, 0x0,
    0x0, 0x3c, 0xff, 0xf8, 0x7d, 0xc1, 0xcf, 0xff,
    0xa3, 0x0, 0x3b, 0xff, 0xff, 0x50, 0x8f, 0xf2,
    0x1a, 0xff, 0xff, 0xc4, 0x7f, 0xff, 0xff, 0xff,
    0xff, 0xff, 0xff, 0xff, 0xff, 0xf2, 0xc, 0xbf,
    0xff, 0xee, 0xee, 0xee, 0xee, 0xff, 0xab, 0x80,
    0x0, 0xe, 0xf9, 0x0, 0x0, 0x0, 0x1, 0xff,
    0x60, 0x0, 0x0, 0xe, 0xff, 0xff, 0xff, 0xff,
    0xff, 0xff, 0x60, 0x0, 0x0, 0xe, 0xfd, 0xbb,
    0xbb, 0xbb, 0xbb, 0xff, 0x60, 0x0, 0x0, 0xe,
    0xf9, 0x0, 0x0, 0x0, 0x1, 0xff, 0x60, 0x0,
    0x0, 0xe, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff,
    0x60, 0x0, 0x0, 0xe, 0xff, 0xff, 0xff, 0xff,
    0xff, 0xff, 0xa0, 0x0, 0x0, 0xe, 0xf9, 0x6,
    0xfb, 0x50, 0x4, 0xcf, 0xf7, 0x0, 0x0, 0xe,
    0xf9, 0xc, 0xff, 0xff, 0xdf, 0xff, 0xb5, 0x0,
    0x0, 0xf, 0xf9, 0x36, 0xdf, 0xff, 0xff, 0xf8,
    0x0, 0x0, 0x0, 0x3f, 0xff, 0xff, 0xfd, 0x17,
    0xef, 0xff, 0xf9, 0x20, 0x0, 0x3f, 0xff, 0xff,
    0xc8, 0x0, 0x5, 0xcf, 0xff, 0x10, 0x0, 0xa,
    0xc8, 0x40, 0x0, 0x0, 0x0, 0x3, 0xb6, 0x0,
    0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0,
    0x0, 0x0
};


/*---------------------
 *  GLYPH DESCRIPTION
 *--------------------*/

static const lv_font_fmt_txt_glyph_dsc_t glyph_dsc[] = {
    {.bitmap_index = 0, .adv_w = 0, .box_w = 0, .box_h = 0, .ofs_x = 0, .ofs_y = 0} /* id = 0 reserved */,
    {.bitmap_index = 0, .adv_w = 95, .box_w = 0, .box_h = 0, .ofs_x = 0, .ofs_y = 0},
    {.bitmap_index = 0, .adv_w = 92, .box_w = 5, .box_h = 4, .ofs_x = 0, .ofs_y = 5},
    {.bitmap_index = 10, .adv_w = 320, .box_w = 21, .box_h = 20, .ofs_x = 0, .ofs_y = -3},
    {.bitmap_index = 220, .adv_w = 320, .box_w = 19, .box_h = 21, .ofs_x = 0, .ofs_y = -4},
    {.bitmap_index = 420, .adv_w = 320, .box_w = 20, .box_h = 21, .ofs_x = 0, .ofs_y = -4},
    {.bitmap_index = 630, .adv_w = 320, .box_w = 19, .box_h = 20, .ofs_x = 1, .ofs_y = -4},
    {.bitmap_index = 820, .adv_w = 320, .box_w = 20, .box_h = 21, .ofs_x = 0, .ofs_y = -4}
};

/*---------------------
 *  CHARACTER MAPPING
 *--------------------*/

static const uint16_t unicode_list_0[] = {
    0x0, 0x97, 0x4f3c, 0x5288, 0x5b46, 0x7700, 0x98bf
};

/*Collect the unicode lists and glyph_id offsets*/
static const lv_font_fmt_txt_cmap_t cmaps[] =
{
    {
        .range_start = 32, .range_length = 39104, .glyph_id_start = 1,
        .unicode_list = unicode_list_0, .glyph_id_ofs_list = NULL, .list_length = 7, .type = LV_FONT_FMT_TXT_CMAP_SPARSE_TINY
    }
};



/*--------------------
 *  ALL CUSTOM DATA
 *--------------------*/

#if LVGL_VERSION_MAJOR == 8
/*Store all the custom data of the font*/
static  lv_font_fmt_txt_glyph_cache_t cache;
#endif

#if LVGL_VERSION_MAJOR >= 8
static const lv_font_fmt_txt_dsc_t font_dsc = {
#else
static lv_font_fmt_txt_dsc_t font_dsc = {
#endif
    .glyph_bitmap = glyph_bitmap,
    .glyph_dsc = glyph_dsc,
    .cmaps = cmaps,
    .kern_dsc = NULL,
    .kern_scale = 0,
    .cmap_num = 1,
    .bpp = 4,
    .kern_classes = 0,
    .bitmap_format = 0,
#if LVGL_VERSION_MAJOR == 8
    .cache = &cache
#endif
};



/*-----------------
 *  PUBLIC FONT
 *----------------*/

/*Initialize a public general font descriptor*/
#if LVGL_VERSION_MAJOR >= 8
const lv_font_t lv_font_yahei_bold_20 = {
#else
lv_font_t lv_font_yahei_bold_20 = {
#endif
    .get_glyph_dsc = lv_font_get_glyph_dsc_fmt_txt,    /*Function pointer to get glyph's data*/
    .get_glyph_bitmap = lv_font_get_bitmap_fmt_txt,    /*Function pointer to get glyph's bitmap*/
    .line_height = 21,          /*The maximum line height required by the font*/
    .base_line = 4,             /*Baseline measured from the bottom of the line*/
#if !(LVGL_VERSION_MAJOR == 6 && LVGL_VERSION_MINOR == 0)
    .subpx = LV_FONT_SUBPX_NONE,
#endif
#if LV_VERSION_CHECK(7, 4, 0) || LVGL_VERSION_MAJOR >= 8
    .underline_position = -2,
    .underline_thickness = 1,
#endif
    .dsc = &font_dsc,          /*The custom font data. Will be accessed by `get_glyph_bitmap/dsc` */
#if LV_VERSION_CHECK(8, 2, 0) || LVGL_VERSION_MAJOR >= 9
    .fallback = NULL,
#endif
    .user_data = NULL,
};



#endif /*#if LV_FONT_YAHEI_BOLD_20*/

